package com.lac.component.test.singleton;

/**
 * @author xiaokuixiao
 * date2025/4/9 13:34
 */
//懒汉式(线程不安全)
class Singleton03{
    private static Singleton03 instance;
    private Singleton03(){

    }

    public static Singleton03 getInstance(){
        if (instance == null){ //未创建才创建
            instance = new Singleton03();
        }
        return instance;
    }

}